﻿@{
    ViewBag.Title = "ViewPage1";
    Layout = "~/Views/Shared/BaseView.cshtml";
}
<script type="text/javascript">
    function showdiv3() {
        if (document.getElementById("table3").style.display == "block") {
            document.getElementById("table3").style.display = "none";
        } else {
            document.getElementById("table3").style.display = "block";
        }

    }
</script>
@{
    Common.Web.Cookie cookie = new Common.Web.Cookie();
    int visiterId = Convert.ToInt32(cookie.GetCookie("LoginUserId"));
    BenefitHelper.DB.DBManager db = new BenefitHelper.DB.DBManager();
    if (BenefitHelper.Sys.VisitPrower.HasAdminPrower(visiterId, db))
    { 
    <div id="buttons">
        <span>
            <p>
                <a href="/Init" target="_blank" title="后台管理">后台管理</a>
            </p>
        </span>
    </div>
    }
    db.Dispose();
}
<dl id="xiangmu">
    <dt><span id="title2">@ViewBag.group.GroupName</span></dt>
    <dd>
        <table width="100%" border="0" cellspacing="0" cellpadding="0" id="group">
            <tr>
                <td style="border-left: 1px solid #ecc7b5;">
                    <a href="/GroupShow/indexShow/@ViewBag.gid/@ViewBag.groupquerydate">
                        <img src="/Content/images/icon_07.gif" />盘中统计</a>
                </td>
                <td>
                    <a href="/GroupCompare/Index/@ViewBag.gid/@ViewBag.pdate">
                        <img src="/Content/images/icon_02.gif" />信息汇总</a>
                </td>
                <td class="selected">
                    <img src="/Content/images/icon_02.gif" />历史数据
                </td>
            </tr>
        </table>
    </dd>
</dl>
<div id="bigDataBox">
    <div class="date-select-bar">
        @for (int i = 1; i <= 12; i++)
        {
            if (!string.IsNullOrEmpty(ViewBag.querymonth.ToString()))
            {


                if (Convert.ToInt32(ViewBag.querymonth) == i)
                {
            <a class='cur'>@i</a>
                }
                else
                {
                    if (i < 10)
                    {
                        string z = "0" + i;
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@ViewBag.queryyear@z">@i</a>
                    }
                    else
                    {
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@ViewBag.queryyear@i">@i</a>
                    }

                }
            }
            else
            {
                if (i < 10)
                {
                    string z = "0" + i;
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@ViewBag.queryyear@z">@i</a>
                }
                else
                {
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@ViewBag.queryyear@i">@i</a>
                }

            }
        }
        @if (string.IsNullOrEmpty(ViewBag.querymonth.ToString()))
        {
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@ViewBag.queryyear" class='cur'>整年数据</a>
        }
        else
        {
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@ViewBag.queryyear">整年数据</a>
        }
    </div>
    <div class="date-select-bar" style="text-align: right; float: right;">
        @for (int i = 2011; i <= DateTime.Now.Year; i++)
        {
            if (Convert.ToInt32(ViewBag.queryyear) == i)
            {
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@i@ViewBag.querymonth" class='cur'>@i</a>
            }
            else
            {
            <a href="/GroupXingNeng/Index/@ViewBag.gid/@i@ViewBag.querymonth">@i</a>
            }
        }
    </div>
    <br />
    <br />
    <div style="height: 5px; line-height: 5px;">
    </div>
    <div style="height: 5px; line-height: 5px;">
    </div>
    <table style="width: 100%;">
        <tr>
            <td style="width: 70%; vertical-align: top;">
                <div style="width: 100%; height: 300px;" id="showflash2">
                </div>
            </td>
            <td>
                <div style="width: 100%; height: 300px;" id="showflash">
                </div>
            </td>
        </tr>
    </table>
    <div style="height: 5px; line-height: 5px;">
    </div>
    <div style="width: 60%; background-repeat: no-repeat; float: left; text-align: left;">
        <img src="/content/images/shouyigaikuang.png" />
    </div>
    @*    <div id="DateSelectBar" class="date-select-bar" style="float: right;">
        <a href="#00" class='cur' onclick="changediv(1)">按交易员</a> <a href="#-1" onclick="changediv(2)">
            按多空</a>
    </div>*@
    <table cellspacing="0" cellpadding="0" class="list" style="width: 100%;" id="table1">
        <tr>
            <td class="title" style="text-align: center;">
                姓名
            </td>
            <td class="title" style="text-align: center;">
                风险次数
            </td>
            <td class="title" style="text-align: center;">
                资金利用率
            </td>
            <td class="title" style="text-align: center;">
                胜率
            </td>
            <td class="title" style="text-align: center;">
                涨幅
            </td>
            <td class="title" style="text-align: center;">
                累计盈亏
            </td>
            <td class="title" style="text-align: center;">
                每笔盈利
            </td>
            <td class="title" style="text-align: center;">
                收益效率
            </td>
        </tr>
        @{
            double sum1 = 0f;
            double sum2 = 0f;
            double sum3 = 0f;
            double sum4 = 0f;
            double sum5 = 0f;
            double sum6 = 0f;
            double sum7 = 0f;
            double sum8 = 0f;
            double sum9 = 0f;
        }
        @if (!string.IsNullOrEmpty(ViewBag.querymonth))
        {
            foreach (BenefitHelper.View.OperatorMonthSum data in ViewBag.changes)
            {
                sum1 += data.RiskCount;
                sum2 += data.Utilization;
                sum3 += data.WinRate;
                sum4 += data.RaiseRate;

                sum6 += data.AvgBillBenefit;
                sum7 += data.RiskCount;
                sum8 += data.Yield;
            <tr>
                <td style="text-align: center;">
                    @data.Operator.UName
                </td>
                <td style="text-align: right;">
                    @data.RiskCount
                </td>
                <td style="text-align: right;">
                    @data.Utilization
                </td>
                <td style="text-align: right;">
                    @data.WinRate
                </td>
                <td style="text-align: right;">
                    @data.RaiseRate
                </td>
                <td style="text-align: right;">
                    @foreach (BenefitHelper.View.OperatorMonthSum c in ViewBag.changes)
                    {
                        if (c.OperatorId == data.OperatorId)
                        {
                        <span>@string.Format("{0:N2}", c.Profit)</span>
                         sum5 += c.Profit;
                         break;
                        }
                    }
                </td>
                <td style="text-align: right;">
                    @string.Format("{0:N2}", data.AvgBillBenefit)
                </td>
                <td style="text-align: right;" class="leftyes">
                    @data.Yield
                </td>
            </tr>
            }
        }
        else
        {
            foreach (BenefitHelper.View.OperatorYearSum data in ViewBag.changes)
            {
                sum1 += data.RiskCount;
                sum2 += data.Utilization;
                sum3 += data.WinRate;
                sum4 += data.RaiseRate;
                sum5 += data.RiskCount;
                sum6 += data.AvgBillBenefit;
                sum7 += data.RiskCount;
                sum8 += data.Yield;
                sum9 += data.RiskCount;
            <tr>
                <td style="text-align: left; padding-left: 10px;">
                    @data.Operator.UName
                </td>
                <td style="text-align: right;">
                    @data.RiskCount
                </td>
                <td style="text-align: right;">
                    @data.Utilization
                </td>
                <td style="text-align: right;">
                    @data.WinRate
                </td>
                <td style="text-align: right;">
                    @data.RaiseRate
                </td>
                <td style="text-align: right;">
                    @foreach (BenefitHelper.View.OperatorYearSum c in ViewBag.changes)
                    {
                        if (c.OperatorId == data.OperatorId)
                        {
                        <span>@string.Format("{0:N2}", c.Profit)</span>
                         sum5 += c.Profit;
                         break;
                        }
                    }
                </td>
                <td style="text-align: right;">
                    @string.Format("{0:N2}", data.AvgBillBenefit)
                </td>
                <td style="text-align: right;" class="leftyes">
                    @data.Yield
                </td>
            </tr>
            }
        }
        <tr>
            <td style="text-align: center;" class="bottomyes">
                总计
            </td>
            <td style="text-align: right;" class="bottomyes">
                @sum1
            </td>
            <td style="text-align: right;" class="bottomyes">
                @sum2
            </td>
            <td style="text-align: right;" class="bottomyes">
                @sum3
            </td>
            <td style="text-align: right;" class="bottomyes">
                @sum4
            </td>
            <td style="text-align: right;" class="bottomyes">
                @string.Format("{0:N2}", sum5)
            </td>
            <td style="text-align: right;" class="bottomyes">
                @string.Format("{0:N2}", sum6)
            </td>
            <td style="text-align: right;" class="bottomyes leftyes">
                @sum8
            </td>
        </tr>
    </table>
    <div style="height: 15px; line-height: 15px;">
    </div>
    <div style="width: 60%; background-repeat: no-repeat; float: left; text-align: left;">
        <img src="/content/images/jiaoyigaikuang.png" alt="" />
    </div>
    <table style="width: 100%;" class="list" cellspacing="0" cellpadding="0">
        <tr>
            <td class="title" style="width: 10%;">
                参数
            </td>
            <td class="title" style="width: 40%;">
                值
            </td>
            <td class="title" style="width: 10%;">
                参数
            </td>
            <td class="title" style="width: 40%;">
                值
            </td>
        </tr>
        <tr class="detailsold" onclick="fee(1)">
            <td>
                <div style="float: left; text-align: left; width: 100%;">
                    平仓盈亏</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;">
                <div class="div1" style="float: right; text-align: right; width: 100%;">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.Profit)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table1">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.Profit)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.Profit)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.Profit)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.Profit)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.Profit)
                                    }
                                </div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.Profit)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
            <td>
                <div style="float: left;">
                    手续费</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;" class="leftyes">
                <div style="float: right; text-align: right; width: 100%;" class="table1">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.Free)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table1">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.Free)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.Free)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.Free)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.Free)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.Free)
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.Free)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
        </tr>
        <tr class="detailsold" onclick="fee(2)">
            <td>
                <div style="float: left;">
                    净利润</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;">
                <div style="float: right; text-align: right; width: 100%;" class="div2">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.DayCount)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table2">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.DayCount)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.DayCount)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.DayCount)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.DayCount)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.DayCount)
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.DayCount)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
            <td>
                <div style="float: left;">
                    交易笔数</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;" class="leftyes">
                <div style="float: right; text-align: right; width: 100%;" class="div2">
                    @ViewBag.groupmonthsum.BillCount</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table2">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @ViewBag.groupmonthsum.BillCount</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupavgyear.BillCount</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupavgmonth.BillCount</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.companyavgmonth.BillCount</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @ViewBag.yesteryearsum.BillCount
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupyestermonthsum.BillCount</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
        </tr>
        <tr class="detailsold" onclick="fee(3)">
            <td>
                <div style="float: left;">
                    平均持仓时长</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;">
                <div style="float: right; text-align: right; width: 100%;" class="div3">
                    @ViewBag.groupmonthsum.AvgPostionTime</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table3">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @ViewBag.groupmonthsum.AvgPostionTime</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupavgyear.AvgPostionTime</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupavgmonth.AvgPostionTime</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.companyavgmonth.AvgPostionTime</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @ViewBag.yesteryearsum.AvgPostionTime
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupyestermonthsum.AvgPostionTime</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
            <td>
                <div style="float: left;">
                    最大回撤</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;" class="leftyes">
                <div style="float: right; text-align: right; width: 100%;" class="div3">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.MaxReturn)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table3">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.MaxReturn)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.MaxReturn)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.MaxReturn)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.MaxReturn)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.MaxReturn)
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.MaxReturn)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
        </tr>
        <tr class="detailsold" onclick="fee(4)">
            <td>
                <div style="float: left;">
                    总亏损</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;">
                <div style="float: right; text-align: right; width: 100%;" class="div4">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.SumLost)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table4">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.SumLost)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.SumLost)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.SumLost)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.SumLost)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.SumLost)
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.SumLost)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
            <td>
                <div style="float: left;">
                    总盈利</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;" class="leftyes">
                <div style="float: right; text-align: right; width: 100%;" class="div4">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.SumWin)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table4">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.SumWin)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.SumWin)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.SumWin)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.SumWin)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.SumWin)
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.SumWin)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
        </tr>
        <tr class="detailsold" onclick="fee(5)">
            <td class="bottomyes">
                <div style="float: left;">
                    保证金占用</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;" class="bottomyes">
                <div style="float: right; text-align: right; width: 100%;" class="div5">
                    @string.Format("{0:N2}", ViewBag.groupmonthsum.UsedMargin)</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table5">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @string.Format("{0:N2}", ViewBag.groupmonthsum.UsedMargin)</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgyear.UsedMargin)</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupavgmonth.UsedMargin)</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.companyavgmonth.UsedMargin)</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @string.Format("{0:N2}", ViewBag.yesteryearsum.UsedMargin)
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @string.Format("{0:N2}", ViewBag.groupyestermonthsum.UsedMargin)</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
            <td class="bottomyes">
                <div style="float: left;">
                    超出止损次数</div>
            </td>
            <td style="padding: 1px 1px 1px 1px;" class="bottomyes leftyes">
                <div style="float: right; text-align: right; width: 100%;" class="div5">
                    @ViewBag.groupmonthsum.OverStopLoss</div>
                <div style="width: 100%; display: none; padding: 1px 1px 1px 1px;" class="table5">
                    <table cellspacing="0" cellpadding="0" class="list2" style="width: 100%; background-color: #f5f7c7">
                        <tr>
                            <td style="text-align: left; width: 25%;" rowspan="4">
                                <div class="raise">
                                    @ViewBag.groupmonthsum.OverStopLoss</div>
                                <div style="color: #535985">
                                    本月
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                </div>
                                <div style="height: 3px; line-height: 3px;">
                                    &nbsp;
                                </div>
                                <div style="font-size: 8pt;">
                                </div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; width: 25%; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupavgyear.OverStopLoss</div>
                                <div style="font-size: 8pt;">
                                    年均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupavgmonth.OverStopLoss</div>
                                <div style="font-size: 8pt;">
                                    小组均值</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.companyavgmonth.OverStopLoss</div>
                                <div style="font-size: 8pt;">
                                    公司均值</div>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        @ViewBag.yesteryearsum.OverStopLoss
                                    }</div>
                                <div style="font-size: 8pt;">
                                    @if (ViewBag.yesteryearsum != null)
                                    {
                                        <span>去年同期</span>
                                    }</div>
                            </td>
                            <td style="text-align: left; padding-left: 10px; background-color: #f5f7c7">
                                <div>
                                    @ViewBag.groupyestermonthsum.OverStopLoss</div>
                                <div style="font-size: 8pt;">
                                    上月值</div>
                            </td>
                        </tr>
                    </table>
                </div>
            </td>
        </tr>
    </table>
    <div style="height: 5px; line-height: 5px;">
    </div>
</div>
@MvcHtmlString.Create(ViewBag.js)
<script type="text/javascript">
    YearBenefit();
    // MonthBenefit(1);
    GroupPie();
    function changeMonth(a) {
        MonthBenefit(a);
    }
</script>
<script type="text/javascript">
    function showorhidden() {
        $(".details").toggle();
    }
    function showDetail() {
        if ($('#ad').attr('class') == "detailsold") {
            $("#ad").removeClass("detailsold").addClass("detailsoldclick");
        } else {
            $("#ad").removeClass("detailsoldclick").addClass("detailsold");
        }
        $(".detailslist").toggle();
    }


    function fff() {
        $(".basehiddendiv").toggle();
        $(".aew").toggle();
        //    $(".detailsold").removeClass("detailsold").addClass("detailsoldclick");
    }

    function fsa(c) {
        var offset = $("#fs").offset();
        if (c == 1) {
            $("#myshowdiv").css("left", offset.left + 5);
            $("#myshowdiv").css("top", offset.top - 175);
        } else {
            $("#myshowdiv").css("left", offset.left - 545);
            $("#myshowdiv").css("top", offset.top - 175);
        }
        $("#myshowdiv").toggle();

    }
    function fee(id) {
        $(".div" + id).toggle();
        $(".table" + id).toggle();
    }
</script>
